<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<ui:fragment xmlns="http://www.w3.org/1999/xhtml"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:p="http://primefaces.org/ui"
	xmlns:ui="http://java.sun.com/jsf/facelets">
	<h:form id="formMenu">
		<p:menubar id="menu" styleClass="menu" rendered="#{login.loginEfetuado()}">
        	<p:submenu label="#{str.menu_item_controle}" icon="ui-icon-pencil" rendered="#{permissao.subMenuControle()}">
            	<p:submenu label="#{str.sub_menu_academias}" rendered="#{permissao.subMenuAcademia()}">
	            	<p:menuitem value="#{str.menu_item_novo}" onclick="PF('novaAcademiaVar').show();" icon="ui-icon-disk" rendered="#{permissao.menuItemNovaAcademia()}" />
	            	<p:menuitem value="#{str.menu_item_consultar}" icon="ui-icon-search" rendered="#{permissao.menuItemConsultarAcademias()}" action="#{direcionador.irConsultarAcademias()}" />
	        	</p:submenu>
        	</p:submenu>
        	<p:submenu label="#{str.menu_item_configuracoes}" icon="ui-icon-gear" rendered="#{permissao.subMenuConfiguracoes()}">
            	<p:submenu label="#{str.sub_menu_perfis_de_usuario}" rendered="#{permissao.subMenuPerfisDeUsuario()}">
	            	<p:menuitem value="#{str.menu_item_novo}" onclick="PF('novoPerfilDeUsuarioVar').show();" icon="ui-icon-disk" rendered="#{permissao.menuItemNovoPerfil()}" />
	            	<p:menuitem value="#{str.menu_item_consultar}" icon="ui-icon-search" rendered="#{permissao.menuItemConsultarPerfis()}" action="#{direcionador.irConsultarPerfisDeUsuario()}" />
	        	</p:submenu>
        	</p:submenu>
		    <p:menuitem value="#{str.menu_item_sair}" icon="ui-icon-close" action="#{login.efetuarLogout}" />
    	</p:menubar>
	</h:form>
</ui:fragment>